package com.an.homework;

public class HomeWork_3 {
    public static void main(String[] args) {
        Cellphone cellphone = new Cellphone();
        cellphone.testwork(new Com() {
            @Override
            public void work() {
                System.out.println("计算没问题");
            }
        });
    }
}

interface Com {
    public void work();
}

class Cellphone{
    public void testwork(Com com){
        com.work();
    }
}
